Skip to content

chore(dev): replace pre-commit with prek - #758

Open
joshuarli wants to merge 1 commit into
mainfrom
refactor/replace-pre-commit-with-prek
Open

joshuarli wants to merge 1 commit into
mainfrom
refactor/replace-pre-commit-with-prek

Conversation

@joshuarli

Copy link
Copy Markdown
Member

Replaces pre-commit with prek as the dev hook runner.

pre-commit was the only reason virtualenv was in uv.lock; removing it drops virtualenv and its transitive dependencies from the lock. Supported hooks move to prek's builtin repo (debug-statements stays remote), and the Makefile install/status messages now use prek. Lockfile version churn is limited to the expected removals plus prek.

Verified: uv lock --check for both project locks, prek validate-config .pre-commit-config.yaml, and the migrated hooks via prek run. A full local run also flags pre-existing whitespace/EOF issues in unmodified fixtures, reproducing with the original config on main.

Refs DI-2930.

pre-commit pulls virtualenv and its command-injection advisories into the dev lock. prek is pre-commit-compatible and manages hook environments with uv, so virtualenv and its transitive dependencies drop out entirely.
@linear-code

linear-code Bot commented Nov 23, 2026

Copy link
Copy Markdown

DI-2930

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant